package com.siemens.industrial.utils;

import java.util.Random;

/**
 * Created by qupen on 2016/10/12.
 */
public class PasswordUtil {
    public static String get(int num) {
        //41--126 的 随机数
        String s = "";
        int i = 0;
        Random r = new Random();
        while (i < num) {
            char character = (char) (r.nextInt(86) + 41);
            i++;
            s = String.valueOf(character) + s;
        }
        System.out.println(s);
        return s;
    }
}


